package cn.itcast.solr;

import cn.itcast.pojo.Item;
import org.apache.solr.client.solrj.impl.HttpSolrServer;
import org.junit.Test;

public class deleteTest {
    @Test
    public void testWrite()throws Exception{
        HttpSolrServer solrServer = new HttpSolrServer("http://localhost:8080/solr/collection1");
        //solrServer.deleteById("10");
        solrServer.deleteByQuery("title:索尼");
        solrServer.commit();
    }
}
